describe('practice-4-2', function () {

    it("求两个正整数的最小公倍数", function () {
        var least_number = least_common_multiple(2,3);
        console.info('least_number:'+least_number);
        expect(least_number).toBe(6);
        expect(least_common_multiple(10,2)).toBe(10);
        expect(least_common_multiple(55,17)).toBe(55*17);
        expect(least_common_multiple(102,51)).toBe(102);
        var temp_m = least_number/2;
        var temp_n = least_number/3;
        while(temp_n>1)
        {
            var temp = temp_m % temp_n;
            if(temp === 0)
            {
                expect(temp_n).toBe(1);
                break;
            }
            temp_m = temp_n;
            temp_n = temp;
        }
    });

});